<html>
  <head>
  </head>
  <body>
    <div id="game"></div>
    <script src="https://rawgithub.com/craftyjs/Crafty/release/dist/crafty-min.js"></script>
    <script>
        var squaresURI = "https://mdn.mozillademos.org/files/2766/squares.gif"

        Crafty.init(600, 300, document.getElementById('game'));
        Crafty.background('rgb(0,0,0)');
        Crafty.viewport.scale(6);
        Crafty.pixelart(true);

        /*
        // Not working on FF
        Crafty.e("2D, Canvas, Image")
            .image(squaresURI);
        */

        /*
        // Not working on Webkit
        Crafty.e("2D, DOM, Image")
            .image(squaresURI);
        */

        //Should work cross-browser
        Crafty.sprite(50, 50, squaresURI, {squares:[0,0]});
        Crafty.e("2D, Canvas, squares");
    </script>
  </body>
</html>
